package com.movitech.mobile.cz.base.purchase.service.impl;

import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.movitech.mobile.cz.base.common.util.CommonConstants;
import com.movitech.mobile.cz.base.purchase.entity.PSpOverallPlanAudits;
import com.movitech.mobile.cz.base.purchase.mapper.PSpOverallPlanAuditsMapper;
import com.movitech.mobile.cz.base.purchase.service.PSpOverallPlanAuditsService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 战略采购年度总规划-审批 服务实现类
 * </p>
 *
 * @author Movitech Mobile
 * @since 2018-09-19
 */
@Service
public class PSpOverallPlanAuditsServiceImpl extends ServiceImpl<PSpOverallPlanAuditsMapper, PSpOverallPlanAudits> implements PSpOverallPlanAuditsService {

    @Override
    public PSpOverallPlanAudits selectByYear(Integer year) {
        PSpOverallPlanAudits pSpOverallPlanAudits = new PSpOverallPlanAudits();
        pSpOverallPlanAudits.setPlanYear(year);
        pSpOverallPlanAudits.setDelFlag(CommonConstants.DEL_FLAG_NORMAL);
        return selectOne(new EntityWrapper<>(pSpOverallPlanAudits));
    }
}
